class Singleton1{
    private volatile static Singleton1 intance=null;
    private static Object locker=new Object();
    public static Singleton1 getIntance(){
        if(intance==null){
            synchronized (locker){
                if(intance==null){
                    intance=new Singleton1();
                }
            }
        }
        return intance;
    }
    private Singleton1(){

    }
}
public class Test11 {
    public static void main(String[] args) {

    }
}
